#include <iostream>
using namespace std;

const int MAXN = 21;
bool hasHorse[MAXN][MAXN];

int countWays(int n, int m) {
    int dp[MAXN][MAXN] = {0};

    dp[0][0] = 1;

    for (int i = 0; i <= n; i++) {
        for (int j = 0; j <= m; j++) {
            if (!hasHorse[i][j]) {
                if (i > 0) {
                    dp[i][j] += dp[i - 1][j];
                }
                if (j > 0) {
                    dp[i][j] += dp[i][j - 1];
                }
            }
        }
    }

    return dp[n][m];
}

bool isInControl(int x, int y, int horseX, int horseY) {
    return (x == horseX - 1 && y == horseY - 2) ||
           (x == horseX - 2 && y == horseY - 1) ||
           (x == horseX - 2 && y == horseY + 1) ||
           (x == horseX - 1 && y == horseY + 2) ||
           (x == horseX + 1 && y == horseY - 2) ||
           (x == horseX + 2 && y == horseY - 1) ||
           (x == horseX + 2 && y == horseY + 1) ||
           (x == horseX + 1 && y == horseY + 2);
}

int main() {
    int n, m, horseX, horseY;
    cin >> n >> m >> horseX >> horseY;

    for (int i = 0; i <= n; i++) {
        for (int j = 0; j <= m; j++) {
            hasHorse[i][j] = false;
        }
    }

    hasHorse[horseX][horseY] = true;
    for (int i = -2; i <= 2; i++) {
        for (int j = -2; j <= 2; j++) {
            if (isInControl(horseX + i, horseY + j, horseX, horseY)) {
                hasHorse[horseX + i][horseY + j] = true;
            }
        }
    }

    int result = countWays(n, m);
    cout << result << endl;
    return 0;
}
